
import java.util.*;

public class offer50 {
    public static void main(String[] args) {
        String s = "abcdefgcd";
        Solution50 sol = new Solution50();
        for(int i = 0; i < s.length(); i++) {
            System.out.println(s.charAt(i));
        }
        System.out.println(sol.firstUniqChar(s)); 

    }
}

class Solution50 {
    public char firstUniqChar(String s) {
        Set<String> set = new HashSet<>();
        for(int i = 0; i < s.length(); i++) {
            char c = s.charAt(i);
            if(set.contains(c)) return c;
            else set.add(c);
        }
        return false;
    }
}


